import { ycCreateRouter } from './YcRouteHistory'

// import { RouterInstance } from './YcRouterData'

// let routes = RouterInstance[1]
// 公共路由
export const CONSTANT_ROUTES = [
  {
    path: '/',
    name: 'TestRouter1Ac',
    // component: TestRouter1AcVue
    component: () => import('@/ui/test/router/TestRouter1Ac.vue')
  },
  {
    path: '/TestRouter2Ac',
    name: 'TestRouter2Ac',
    component: () => import('@/ui/test/router/TestRouter2Ac.vue')
  },
  {
    path: '/TestRouter3Ac',
    name: 'TestRouter3Ac',
    redirect:"/TestRouter3Ac/TestRouter31Fra",
    component: () => import('@/ui/test/router/TestRouter3Ac.vue'),
    children: [
      {
        path: '',
        name: 'TestRouter31Fra',
        component: () => import('@/ui/test/router/TestRouter31Fra.vue')
      },
      {
        path: 'TestRouter32Fra',
        name: 'TestRouter32Fra',
        component: () => import('@/ui/test/router/TestRouter32Fra.vue')
      }
    ]
  },
  {
    path: '/TestSameNameAc',
    name: 'TestSameNameAc',
    component: () => import('@/ui/test/ui/TestSameNameAc.vue')
  },
  {
    path: '/TestSameNameAc',
    name: 'TestSameNameAc',
    component: () => import('@/ui/test/TestSameNameAc.vue')
  },
  // {
  //   path: '/',
  //   name: 'TestImgPreAc',
  //   component: TestImgPreAc
  // },
  // {
  //   path: '/',
  //   name: 'TestLoadingVue',
  //   component: TestLoadingAc
  // },
  // {
  //   path: '/',
  //   name: 'TestDemoAc',
  //   component: TestDemoAc
  // },
  // {
  //   path: '/',
  //   name: 'TestUiAc',
  //   component: TestUiAc
  // },
  // {
  //   path: '/',
  //   name: 'TestToAc1Vue',
  //   component: TestToAc1Vue
  // },
  // {
  //   path: '/TestToAc2Vue',
  //   name: 'TestToAc2Vue',
  //   component: TestToAc2Vue
  // },
  // {
  //   path: '/',
  //   name: 'TestCssVue',
  //   component: TestCssVue
  // },
  // {
  //   path: '/',
  //   name: 'YcTestVue',
  //   component: YcTestVue
  // },

  // {
  //   path: '/',
  //   name: 'YcWatch',
  //   component: YcWatch
  // },
  // {
  //   path: '/',
  //   name: 'YcParentVue',
  //   component: YcParentVue
  // },
  // {
  //   path: '/',
  //   name: 'welcomeAc',
  //   component: WelcomeAc
  // },
  {
    path: "/loginAc",
    name: "loginAc",
    meta: {
      hasTokenExpired: false
    },
    component: () => import('../ui/common/LoginAc.vue')
  },
  {
    path: '/MainAc',
    name: 'MainAc',
    children: [
      {
        path: 'MainFra1',
        name: 'MainFra1',
        // components: {
        //   default: import('@/ui/common/MainFra1.vue')
        // },
        component: () => import('../ui/common/MainFra1.vue')
      },
      {
        path: 'MainFra2',
        name: 'MainFra2',
        component: () => import('../ui/common/MainFra2.vue')
      }
    ]
  }
]

export const mRouterInstance = ycCreateRouter(CONSTANT_ROUTES)
